<!--
 * @Author: 淹死De鱼5 happyjing5@sina.cn
 * @Date: 2024-03-16 01:53:16
 * @LastEditors: 淹死De鱼5 happyjing5@sina.cn
-->
<!--  -->
<template>
  <el-dialog v-bind="$attrs" title="分润记录" :visible.sync="visibleComputed" width="750px" append-to-body>
    <el-table v-loading="tableLoading" :data="tableList">
      <el-table-column type="index" label="序号" width="50" />
      <el-table-column label="分润金额" align="center" prop="contactName" width="150" />
      <el-table-column label="介绍人" align="center" prop="contactName" width="150" />
      <el-table-column label="分润比例" align="center" prop="contactName" width="150" />
      <el-table-column label="时间" align="center" prop="contactName"/>
    </el-table>
    <div slot="footer" class="dialog-footer">
      <el-button :loading="isLoading" type="primary" @click="submitForm">确 定</el-button>
      <el-button @click="cancel">取 消</el-button>
    </div>
  </el-dialog>
</template>

<script>
import { shareMoneyTaskList } from '@/api/reward/contact.js'
export default {
  dicts: ['check_task_status'],
  components: {},
  props: {
    visible: {
      type: Boolean,
      default: false
    },
    id: {
      type: String|Number,
      default: ''
    }
  },
  data () {
    return {
      isLoading: false,
      tableLoading: false,
      tableList:[],
      form: {},
      // 表单校验
      rules: {
        contactStatus: [
          { required: true, message: "状态不能为空", trigger: "blur" }
        ],
      }
    }
  },
  computed: {
    visibleComputed: {
      get() {
        return this.visible
      },
      set(value) {
        return this.$emit('update:visible', value)
      }
    }
  },
  mounted() {},
  methods: {
    // 获取承接人列表
    getMemberList() {
      const postData = {
        ...this.queryParams,
        postedId: this.id,
        nodeOrigin: 0
      }
      shareMoneyTaskList(postData).then(response => {
        this.tableList = response.rows;
        this.total = response.total;
        this.loading = false;
        console.log(response)
      })
    },
    submitForm() {
      const el = this
      el.isLoading = true
      this.cancel()
      console.log(postData)
    },
    cancel() {
      this.$emit('update:visible', false)
    }
  }
}
</script>
<style lang='scss' scoped>
</style>
